/////////////////////////////////////////////////////////////////////////////////
//
//  Please read the comments in GSP320.cpp under
//		- void GSP320::ballSetup()
//	... and the comments in Ball.cpp under
//		- Ball::Ball()
//		- void Ball::update(float dt)
//	... for information on what the students should be changing.
//	All other code should remain the way it is.
//	WARNING - 2 memory leaks are in this program.
//
/////////////////////////////////////////////////////////////////////////////////


//precompiled headers to include
#include <tchar.h>
#include <crtdbg.h>

//our classes and stuff to include
#include "d3dApp.h"
#include "GSP320.h"

	
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE prevInstance, PSTR cmdLine, int showCmd)
{
	// Enable run-time memory check for debug builds.
	#if defined(DEBUG) | defined(_DEBUG)
		_CrtSetDbgFlag( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF );
	#endif

	srand ( (unsigned int)time(NULL) );

	//this is the constructor for our class, right now about the only thing we shd change is the title of the 
	//window
	GSP320 app(hInstance, "GSP 320 Example Engine", D3DDEVTYPE_HAL, D3DCREATE_HARDWARE_VERTEXPROCESSING);
	gd3dApp = &app;

	//Configure DInput here
	DInput di(DISCL_NONEXCLUSIVE | DISCL_FOREGROUND, DISCL_FOREGROUND | DISCL_NONEXCLUSIVE, DISCL_FOREGROUND | DISCL_EXCLUSIVE);
	gDInput = &di;

	
	return gd3dApp->run();
}

